#region Imports

using System;
using Microsoft.SharePoint.Utilities;

#endregion

namespace Backend.Services.SP2007
{

    /// <summary>
    /// Provides navigation services for SharePoint 2007.
    /// </summary>
    internal sealed class SP2007NavigationService : NavigationService
    {

        #region Methods - Instance Member

        #region Methods - Instance Member - INavigationService Members

        /// <summary>
        /// Navigates to the requesting view.
        /// </summary>
        public override void NavigateToRequestingView()
        {
            // TODO: implement
        }

        /// <summary>
        /// Navigates to the error view, displaying the specified exception.
        /// </summary>
        /// <param name="exception">
        /// The exception to be displayed on the error page.
        /// </param>
        public override void NavigateToErrorView(Exception exception)
        {
            this.NavigateToErrorView(exception.ToString());
        }

        /// <summary>
        /// Navigates to the error view, displaying the specified message.
        /// </summary>
        /// <param name="message">
        /// The message to be displayed on the error page.
        /// </param>
        public override void NavigateToErrorView(string message)
        {
            SPUtility.TransferToErrorPage(message);
        }

        #endregion

        #endregion

    }

}
